|
Server : Apache System : Linux server.mata-lashes.com 3.10.0-1160.90.1.el7.x86_64 #1 SMP Thu May 4 15:21:22 UTC 2023 x86_64 User : matalashes ( 1004) PHP Version : 8.1.29 Disable Function : NONE Directory : /usr/share/systemtap/examples/security-band-aids/ |
Upload File : |
%{
#include <linux/perf_event.h>
%}
function sanitize_config:long (event:long) %{
struct perf_event *event;
#if STAP_COMPAT_VERSION >= STAP_VERSION(1,8)
event = (struct perf_event *) (unsigned long) STAP_ARG_event;
#else
event = (struct perf_event *) (unsigned long) THIS->event;
#endif
event->attr.config &= INT_MAX;
%}
probe kernel.function("perf_swevent_init").call {
sanitize_config($event);
}